//
//  MMGGameSYSSettings.m
//  DollsVending
//
//  Created by Don on 2017/9/10.
//
//

#import "MMGGameSYSSettings.h"

@interface MMGGameSYSSettings ()
@property (nonatomic, assign) BOOL appIsReviewing;
@property (nonatomic, copy) NSString *productId;
@end
@implementation MMGGameSYSSettings
SYNTHESIZE_SINGLETON_FOR_CLASS(MMGGameSYSSettings);
@synthesize rtmpAddress = _rtmpAddress;
@synthesize price = _price;
@synthesize userAuthCode = _userAuthCode;
@synthesize gameControlServerAddr = _gameControlServerAddr;
@synthesize deviceId = _deviceId;
@synthesize cameraChannel = _cameraChannel;

- (void)mmg_gameSystemSettings:(NSArray *)arguments {
    NSString* rtmpAddress = kVIDEO_SERVICE_HOST;
    //商品（公仔）ID******
    NSString* productId = [arguments mg_objectAtIndex:0];
    //商品（公仔）价钱，一局币额
    NSString* price = [arguments mg_objectAtIndex:1];
    //用户登录授权CODE
    NSString* userAuth = [arguments mg_objectAtIndex:2];
    self.appIsReviewing = [[arguments mg_objectAtIndex:3] boolValue];
    //控制服务器地址
    DLog(@"self.app is revwing %d",[[arguments mg_objectAtIndex:3] boolValue]);
    NSString* controlServerAddress = kSERVICE_HOST;//@"139.199.191.99";
    //测试设备ID，以后为通过传productId上服务器，然后在服务器转换成deviceNO,目前暂时还未实现，所以先这样。
//    NSString* deviceNo = kPRIZE_CLAW_MACHINE_ID;//@"39d760f68c154f8fbc5cfda8be175a27";
    _rtmpAddress = rtmpAddress;
    _productId = productId;
    _price = price;
    _userAuthCode = userAuth;
    _gameControlServerAddr = controlServerAddress;
    
    _cameraChannel = 0;//每次被网页调用都默认为0
//    _deviceId = deviceNo;
}
@end
